#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <unistd.h>

#ifndef __URI_H_
#define __URI_H_

typedef struct uri_t {

   int sockfd;
   FILE *fp;

   char *protocol;
   char *host;
   char *resource;
   int port;
   int response;
   char *content;
   char *file;
   long int length;
   int progress;
   int time;
   long int bytes;
   float bps;

} URI;

URI * split_uri(char *);
void uritolower(char *);
char * new_file(char *, int);

#endif
